package com.boco.biinjectionserviceapi.service.config;

import com.baomidou.mybatisplus.extension.service.IService;
import com.boco.biinjectionserviceapi.model.config.SqlTemplateInfo;
import com.boco.biinjectionserviceapi.vo.Params;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/***
 * 根据SQL模板执行在对应的数据源中执行SQL
 */
public interface ISqlTemplateInfoService extends IService<SqlTemplateInfo> {

    /**
     * 通过SQL参数查询数据
     * @param sqlTemplateInfoId
     * @return
     * @throws Exception
     */
    List<HashMap<String, Object>> query(Long sqlTemplateInfoId) throws Exception;


    Map<String, Float> queryByParams(long id1,long id2, Params params) throws Exception;

    List<HashMap<String, Object>> queryByParams(long l, Params params) throws Exception;
}
